Optimal. Leaf size=203 \[ \frac{(a+b x)^{m+1} (c+d x)^{-m-1} \left (-c d (a f h (m+1)+b (e h+f g))+d f h (m+1) x (b c-a d)+b c^2 f h (m+2)+b d^2 e g\right )}{b d^2 (m+1) (b c-a d)}-\frac{(a+b x)^m (c+d x)^{-m} \left (-\frac{d (a+b x)}{b c-a d}\right )^{-m} \, _2F_1\left (-m,-m;1-m;\frac{b (c+d x)}{b c-a d}\right ) (a d f h m+b (d (e h+f g)-c f h (m+2)))}{b d^3 m} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.106725, antiderivative size = 205, normalized size of antiderivative = 1.01, number of steps used = 3, number of rules used = 3, integrand size = 29, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.103, Rules used = {143, 70, 69} \[ -\frac{(a+b x)^{m+1} (c+d x)^{-m-1} \left (-d f h (m+1) x (b c-a d)+a c d f h (m+1)-b \left (c^2 f h (m+2)-c d (e h+f g)+d^2 e g\right )\right )}{b d^2 (m+1) (b c-a d)}-\frac{(a+b x)^m (c+d x)^{-m} \left (-\frac{d (a+b x)}{b c-a d}\right )^{-m} \, _2F_1\left (-m,-m;1-m;\frac{b (c+d x)}{b c-a d}\right ) (a d f h m-b c f h (m+2)+b d (e h+f g))}{b d^3 m} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 143
Rule 70
Rule 69
Rubi steps
\begin{align*} \int (a+b x)^m (c+d x)^{-2-m} (e+f x) (g+h x) \, dx &=-\frac{(a+b x)^{1+m} (c+d x)^{-1-m} \left (a c d f h (1+m)-b \left (d^2 e g-c d (f g+e h)+c^2 f h (2+m)\right )-d (b c-a d) f h (1+m) x\right )}{b d^2 (b c-a d) (1+m)}+\frac{(b d (f g+e h)+a d f h m-b c f h (2+m)) \int (a+b x)^m (c+d x)^{-1-m} \, dx}{b d^2}\\ &=-\frac{(a+b x)^{1+m} (c+d x)^{-1-m} \left (a c d f h (1+m)-b \left (d^2 e g-c d (f g+e h)+c^2 f h (2+m)\right )-d (b c-a d) f h (1+m) x\right )}{b d^2 (b c-a d) (1+m)}+\frac{\left ((b d (f g+e h)+a d f h m-b c f h (2+m)) (a+b x)^m \left (\frac{d (a+b x)}{-b c+a d}\right )^{-m}\right ) \int (c+d x)^{-1-m} \left (-\frac{a d}{b c-a d}-\frac{b d x}{b c-a d}\right )^m \, dx}{b d^2}\\ &=-\frac{(a+b x)^{1+m} (c+d x)^{-1-m} \left (a c d f h (1+m)-b \left (d^2 e g-c d (f g+e h)+c^2 f h (2+m)\right )-d (b c-a d) f h (1+m) x\right )}{b d^2 (b c-a d) (1+m)}-\frac{(b d (f g+e h)+a d f h m-b c f h (2+m)) (a+b x)^m \left (-\frac{d (a+b x)}{b c-a d}\right )^{-m} (c+d x)^{-m} \, _2F_1\left (-m,-m;1-m;\frac{b (c+d x)}{b c-a d}\right )}{b d^3 m}\\ \end{align*}
Mathematica [A] time = 0.249263, size = 198, normalized size = 0.98 \[ \frac{(a+b x)^m (c+d x)^{-m} \left (\frac{(m+1) (b c-a d) \left (\frac{d (a+b x)}{a d-b c}\right )^{-m} \, _2F_1\left (-m,-m;1-m;\frac{b (c+d x)}{b c-a d}\right ) (-a d f h m+b c f h (m+2)-b d (e h+f g))}{m}-\frac{d (a+b x) \left (a d f h (m+1) (c+d x)-b \left (c^2 f h (m+2)+c d (-e h-f g+f h (m+1) x)+d^2 e g\right )\right )}{c+d x}\right )}{b d^3 (m+1) (b c-a d)} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [F] time = 0.054, size = 0, normalized size = 0. \begin{align*} \int \left ( bx+a \right ) ^{m} \left ( dx+c \right ) ^{-2-m} \left ( fx+e \right ) \left ( hx+g \right ) \, dx \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int{\left (f x + e\right )}{\left (h x + g\right )}{\left (b x + a\right )}^{m}{\left (d x + c\right )}^{-m - 2}\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F] time = 0., size = 0, normalized size = 0. \begin{align*}{\rm integral}\left ({\left (f h x^{2} + e g +{\left (f g + e h\right )} x\right )}{\left (b x + a\right )}^{m}{\left (d x + c\right )}^{-m - 2}, x\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int{\left (f x + e\right )}{\left (h x + g\right )}{\left (b x + a\right )}^{m}{\left (d x + c\right )}^{-m - 2}\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]